
<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>完善个人信息</title>
	<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
    <meta content="yes" name="apple-mobile-web-app-capable">
    <meta content="black" name="apple-mobile-web-app-status-bar-style">
    <meta content="telephone=no" name="format-detection">
	<link rel="stylesheet" href="#(root)assets/weui/weui.css">
	<link rel="stylesheet" href="#(root)assets/jweui/css/jquery-weui.css">
	<link rel="stylesheet" href="#(root)assets/jweui/css/style.css">
	<style>
	html,body{ background:#f4f4f4; }
	.weui-cells{ font-size: 15px; }
	.head{
	text-align: center;
	height: 45px;
	line-height: 45px;
	box-shadow: 0 1px 1px 1px #e4e4e4;
	background:#fff;
	position: fixed;
	left: 0;
	top: 0;
	z-index: 100;
	width: 100%;
}
.head .return{
	position: absolute;
	left: 0;
	top: 0;
	width: 45px;
	height: 45px;
}
.head .return:after{
	content: " ";
    display: inline-block;
    height: 13px;
    width: 13px;
    border-width: 2px 2px 0 0;
    border-color: #C8C8CD;
    border-style: solid;
    -webkit-transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
    transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
    position: absolute;
    transform:rotate(225deg);
    left: 16px;
    top: 14px;
}
.head .operation{
	position: absolute;
	right: 0;
	top: 0;
	width: 60px;
	height: 45px;
	color:#00d26d;
}

.personal .tx{
	width: 60px;
	height: 60px;
	border-radius: 50%;
}
.personal .weui-input{
	color: #3d4145;
}
.weui-uploader__input-box:before, .weui-uploader__input-box:after{
background-color:transparent;

}
	</style>
</head>
<body>
	<!-- 
   <div class="head"><a href="index.html" class="return"></a>编辑个人信息 <a href="个人信息.html" class="operation">保存</a></div>
	 -->
   <div class="personal" >
   <form action="up" method="post">
   
          	<div class="weui-cells m0">
			  <div class="weui-cell weui-cell_access">
			    <div class="weui-cell__bd">
			      头像
			    </div>
			    <div class="">
			    	<div id="imgshow" class="weui-uploader__input-box" style="border-radius: 80px;
			    	background-image: url(#((obj.img==null||obj.img=='')?'/img/noav.jpg':root+obj.img));background-size: 100% 100%;">
			    	  <input id="img" type="hidden" name="img" value="" />
                      <input id="av" class="weui-uploader__input" type="file" accept="image/*" multiple="">
                	</div>
				</div>
				
			    <div class="weui-cell__ft">
			    </div>
			  </div>
			  <div style="margin-left: 120px;">上传名片照片，让更多人认识你!</div>
			</div>
			
			<div class="weui-cells mt5">
			<div class="weui-cells__title">基本资料</div>
			   <div class="weui-cell">
			    <div class="weui-cell__bd">
			      手机号码
			    </div>
			    <div class="">#(obj.phone)</div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      称呼<font color="red">*</font>
			    </div>
			    <div class="">
			    <input type="hidden" name="id" value="#(obj.id)">
			    <input type="text" required="required" name="name" class="weui-input tar" placeholder="建议填写您的真实姓名" value="#(obj.name)">
			    </div>
			  </div>
			  <div class="weui-cell weui-cell_access">
			    <div>性别<font color="red">*</font></div>
			    <div class="weui-cell__bd">
			      <input type="text" required="required" name="sex" class="weui-input tar" id='picker' placeholder="请选择" value="#(obj.sex)">
			    </div>
			    <div class="weui-cell__ft">
			    </div>
			  </div>
			  <div class="weui-cell weui-cell_access">
			    <div>出生年月<font color="red">*</font></div>
			    <div class="weui-cell__bd">
			      <input type="text" required="required" name="birthday" class="weui-input tar" id='time' placeholder="请选择" value="#(obj.birthday)">
			    </div>
			    <div class="weui-cell__ft">
			    </div>
			  </div>
			  <div class="weui-cell weui-cell_access">
			    <div>所在城市<font color="red">*</font></div>
			    <div class="weui-cell__bd">
			      <input class="weui-input tar" required="required" name="area" type="text" id="city-picker2" placeholder="请选择地区" value="#(obj.area)">
			    </div>
			    <div class="weui-cell__ft">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div>微信</div>
			    <div class="weui-cell__bd">
			      <input type="text" name="wx" class="weui-input tar" value="#(obj.wx)" placeholder="">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div>QQ</div>
			    <div class="weui-cell__bd">
			      <input type="text" name="qq" class="weui-input tar" value="#(obj.qq)" placeholder="">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div>电子邮箱</div>
			    <div class="weui-cell__bd">
			      <input type="email" name="email" class="weui-input tar" value="#(obj.email)" placeholder="你的邮箱">
			    </div>
			  </div>
			  
	  <div class="weui-cell">
	    <div class="weui-cell__bd">
	      <textarea required="required" name="readme" class="weui-textarea" id="weui-textarea" placeholder="请用一句话介绍自己" maxlength="200" rows="2">#(obj.readme)</textarea>
	    </div>
	  </div>
			</div>
			<div class="weui-cells mt5">
			<div class="weui-cells__title">教育经历</div>
			   <div class="weui-cell">
			    <div class="weui-cell__bd">
			     毕业学院
			    </div>
			    <div class="">
			    <input type="text" name="academy" class="weui-input tar" placeholder="输入毕业学院" value="#(obj.academy)">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      毕业时间
			    </div>
			    <div class="">
			    <input type="text" name="bysj" class="weui-input tar" id='bysj' value="#(obj.bysj)" placeholder="毕业时间">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      专业
			    </div>
			    <div class="">
			    <input type="text" name="zy" class="weui-input tar" placeholder="输入专业" value="#(obj.zy)">
			    </div>
			  </div>
			  
			</div>
			
			<div class="weui-cells mt5">
			<div class="weui-cells__title">职业信息</div>
			   <div class="weui-cell">
			    <div class="weui-cell__bd">
			     单位
			    </div>
			    <div class="">
			    <input type="text" name="unit" class="weui-input tar" placeholder="输入单位" value="#(obj.unit)">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      部门
			    </div>
			    <div class="">
			    <input type="text" name="depart" class="weui-input tar" placeholder="输入部门" value="#(obj.depart)">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      职位
			    </div>
			    <div class="">
			    <input type="text" name="post" class="weui-input tar" placeholder="输入职位" value="#(obj.post)">
			    </div>
			  </div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      	其他身份
			    </div>
			    <div class="">
			    <input type="text" name="other" class="weui-input tar" placeholder="例：注册心理师；XX市心理健康协会委员" value="#(obj.other)">
			    </div>
			  </div>
			</div>
			
			<div class="weui-cells mt5">
			<div class="weui-cells__title">我擅长的</div>
			   <div class="weui-cell">
			    <div class="weui-cell__bd">
			     <textarea name="field" class="weui-textarea" id="weui-textarea" placeholder="我擅长的:例：恋爱心理学、
			     精神分析，尤其是面向大学生的讲座。" maxlength="200" rows="2">#(obj.field)</textarea>
			    </div>
			  </div>
			  <div class="weui-cells__title">我对什么感兴趣<font color="red">*</font></div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      <textarea name="hobby" class="weui-textarea" placeholder="工作上和生活中都可以写一写，例：
工作：大学生心理健康、心理科研；
生活：瑜伽、野生动物保护" maxlength="500" rows="3">#(obj.hobby)</textarea>
			    </div>
			  </div>
			  <div class="weui-cells__title">我能提供什么</div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      <textarea name="provide" class="weui-textarea" placeholder="例：①大学生恋爱相关主题的讲座（线上或线下）；
②人脉资源-国内顶尖心理督导师资源；
③心理咨询帮助团队（校企合作形式）" maxlength="500" rows="3">#(obj.provide)</textarea>
			    </div>
			  </div>
			  <div class="weui-cells__title">我需要什么</div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      <textarea name="need" class="weui-textarea" placeholder="请简要的填写，例：
①资金（用于科研课题的数据收集）；
②想法（想打造一个火爆的线下沙龙，旨在让大学生直接感受到心理学的作用，从而更加相信心理学，最好是大学生恋爱主题）；
③场地（可容纳30人以上的心理活动室）；
④人（统计学比较好的老师，指导下实验设计方案及数据处理方案；此外，还需要有兴趣合作上述“打造爆款校园沙龙”项目的合作者）"
 maxlength="1000" rows="9">#(obj.need)</textarea>
			    </div>
			  </div>
			  <div class="weui-cells__title">当前所专注的事</div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      <textarea name="current" class="weui-textarea" placeholder="请简要的填写，例：
①大学生恋爱态度与成长环境的关系研究；
②如何改善、提升大学生恋爱态度的方法。"
 maxlength="1000" rows="3">#(obj.current)</textarea>
			    </div>
			  </div>
			  <div class="weui-cells__title">其他</div>
			  <div class="weui-cell">
			    <div class="weui-cell__bd">
			      <textarea name="worth" class="weui-textarea" placeholder=""
 maxlength="1000" rows="2">#(obj.worth)</textarea>
			    </div>
			  </div>
			  
			  <div style="padding:10px;">
       			<button class="weui-btn weui-btn_primary">提 交</button>	
    		</div>
			</div>
			
   </form>
          </div>
    
    
   
    

	<script src="#(root)assets/jquery/jquery.min.js"></script>
	<script src="#(root)assets/jweui/js/jquery-weui.min.js"></script>
	<script src="#(root)assets/jweui/js/city-picker.min.js"></script>
	<script src="#(root)assets/weuijs/lrz.min.js"></script>

	<script>
	    // 地区
		$("#city-picker2").cityPicker({
			title:"所在城市",
		    showDistrict: true
		  });
	    // 性别
	    $("#picker").picker({
		  title: "性别",
		  cols: [
		    {
		      textAlign: 'center',
		      values: ['男', '女']
		    }
		  ]
		});

		// 出生年月
		$("#time").datetimePicker({
			title: '出生年月',
        	times: function () {},
	        onChange: function (picker, values, displayValues) {
	          console.log(values);
	        }
      });
		$("#bysj").datetimePicker({title:"毕业时间",times: function () {}})
		$(function(){
	      	var $imgshow = $("#imgshow");
	      	var $av = $("#av");
	        $img = $("#img");
	        $av.on("change", function(e){
	            var src, url = window.URL || window.webkitURL || window.mozURL, files = e.target.files;
	            for (var i = 0, len = files.length; i < len; ++i) {
	                var file = files[i];
	                lrz(file,{width:640,fieldName:"file"}).then(function (rst) {
	   	             var xhr = new XMLHttpRequest();
	   	             xhr.open('POST', '#(root)v1/upload/up.json');
	   	             xhr.onload = function () {
	   	                 if (xhr.status === 200) {
	   	                 var obj = eval('(' + xhr.responseText + ')');
	   	              	 $imgshow.css("background-image","url('#(root)"+obj.file+"')")
	   	              	 $img.val(obj.file);
	   	                 } 
	   	             };
	   	             rst.formData.append('size', rst.fileLen);// 添加参数
	   	             rst.formData.append('base64', rst.base64);
	   	             xhr.send(rst.formData);// 触发上传
	   	             return rst;
	   	         })
	   	         .catch(function (err) {alert(err);})
	   	         .always(function () {});// 不管是成功失败，这里都会执行
	            }
	        });
	        
	        /*$uploaderFiles.on("click", "li", function(){
	            $galleryImg.attr("style", this.getAttribute("style"));
	            $gallery.fadeIn(100);
	        });
	        $gallery.on("click", function(){
	            $gallery.fadeOut(100);
	        });*/
	    });
	</script>
</body>
</html>